<?php
global $dktmSetting;
/**
 * The Header for our theme.
 *
 * Displays all of the <head> section and everything up till <div id="main">
 *
 * @package Ending Credits
 */
?><!DOCTYPE html>
<!--[if IE 6]>
<html id="ie6" <?php language_attributes(); ?>>
<![endif]-->
<!--[if IE 7]>
<html id="ie7" <?php language_attributes(); ?>>
<![endif]-->
<!--[if IE 8]>
<html id="ie8" <?php language_attributes(); ?>>
<![endif]-->
<!--[if !(IE 6) | !(IE 7) | !(IE 8)  ]><!-->
<html <?php language_attributes(); ?>>
    <!--<![endif]-->
    <head>
        <meta charset="<?php bloginfo('charset'); ?>" />
        <meta name="viewport" content="width=device-width" />
        <title><?php
            /*
             * Print the <title> tag based on what is being viewed.
             */
            global $page, $paged;

            wp_title('|', true, 'right');

// Add the blog name.
            bloginfo('name');

// Add the blog description for the home/front page.
            $site_description = get_bloginfo('description', 'display');
            if ($site_description && ( is_home() || is_front_page() ))
                echo " - $site_description";

// Add a page number if necessary:
            if ($paged >= 2 || $page >= 2)
                echo ' | ' . sprintf(__('Page %s', 'ec'), max($paged, $page));
            ?></title>
        <link rel="shortcut icon" href="<?php echo get_template_directory_uri(); ?>/images/dktm.ico" />
        <link rel="profile" href="http://gmpg.org/xfn/11" />
        <link rel="stylesheet" type="text/css" media="all" href="<?php bloginfo('stylesheet_url'); ?>" />
        <link rel="stylesheet" type="text/less" media="all" href="<?php echo get_template_directory_uri(); ?>/css/layout.less" />
        <link rel="stylesheet" type="text/css" media="all" href="<?php echo get_template_directory_uri(); ?>/css/animation.css" />

        <script src="<?php echo get_template_directory_uri(); ?>/js/jquery-1.8.3.min.js" type="text/javascript"></script>
        <script src="<?php echo get_template_directory_uri(); ?>/js/html5.js" type="text/javascript"></script>
        <script src="<?php echo get_template_directory_uri(); ?>/js/main.js" type="text/javascript"></script>
        <script src="<?php echo get_template_directory_uri(); ?>/js/jquery.bxslider.min.js" type="text/javascript"></script>
        <script src="<?php echo get_template_directory_uri(); ?>/js/less.js" type="text/javascript"></script>
        <link href='http://fonts.googleapis.com/css?family=Oswald:400,700' rel='stylesheet' type='text/css'>
        <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,600,700,300' rel='stylesheet' type='text/css'>
        <?php if (is_singular() && get_option('thread_comments')) wp_enqueue_script('comment-reply'); ?>
        <link rel="pingback" href="<?php bloginfo('pingback_url'); ?>" />
        <!--[if lt IE 9]>
        <script src="<?php echo get_template_directory_uri(); ?>/js/html5.js" type="text/javascript"></script>
        <![endif]-->

        <link rel="stylesheet" href="<?php echo get_template_directory_uri(); ?>/assets/jquery.notice/jquery.notice.css" />
        <script type="text/javascript" src="<?php echo get_template_directory_uri(); ?>/assets/jquery.notice/jquery.notice.js"></script>
        <script src="<?php echo get_template_directory_uri(); ?>/assets/colorbox/jquery.colorbox-min.js" type="text/javascript"></script>
        <link rel="stylesheet" type="text/css" media="all" href="<?php echo get_template_directory_uri(); ?>/assets/colorbox/example1/colorbox.css" />


        <?php wp_head(); ?>
        <script src="<?php echo get_template_directory_uri(); ?>/js/jquery.masonry.min.js"></script>

        <link rel="stylesheet" type="text/css" href="<?php echo get_template_directory_uri(); ?>/assets/bootstrap-select/bootstrap-select.css">
        <script type="text/javascript" src="<?php echo get_template_directory_uri(); ?>/assets/bootstrap-select/bootstrap-select.js"></script>
        <link href="<?php echo get_template_directory_uri(); ?>/assets/bootstrap-select/bootstrap.custom.css" rel="stylesheet">
        <script src="<?php echo get_template_directory_uri(); ?>/assets/bootstrap-select/bootstrap.min.js"></script>



        <link rel='stylesheet'  href='<?php echo get_template_directory_uri(); ?>/assets/jquery-dropdown/jquery.dropdown.css' type='text/css' media='all' />

        <script type='text/javascript' src='<?php echo get_template_directory_uri(); ?>/assets/jquery-dropdown/jquery.dropdown.js'></script>

        <link rel='stylesheet'  href='<?php echo get_template_directory_uri(); ?>/assets/font-awesome/css/font-awesome.min.css' type='text/css' media='all' />
        <!--<script src="<?php echo get_template_directory_uri(); ?>/js/jquery.infinitescroll.min.js"></script>-->
        <style>
<?php if (!is_user_logged_in()) { ?>  
                .pfs-post-box-class{
                    height: 250px!important;
                }
<?php } ?> 
            img{
                max-width: 100%;
                xheight: auto;
            }
            .home_box_icon{
                vertical-align: top;
                padding-right: 10px;
            }
            .colorbox_popup_wrapper{
                xwidth: 960px;
            }
            
            strong.title{
                border-bottom: 1px solid #CCCCCC;
                color: #0489C0;
                display: block;
                margin: 15px 0 10px;
            }

            .todays_title{
                background: none repeat scroll 0 0 #DFDFDF;
                color: #717171;
                padding: 10px;
            }
            .full_width_img{
                float: none!important;
                text-align: center!important;
            }
            .group_listing .sliderImage h2{
                color: #FFFFFF;
                display: block;
                font-size: 32px;
                font-weight: bold;
                position: absolute;
                text-align: center;
                top: 65px;
                width: 100%;
                z-index: 0;
                line-height: 1em;
            }
            .description{
                margin-bottom: 20px;
            }
            .description p{
                margin: 10px 0;
            }
            .sub-single-page{
                margin-bottom: 40px;
            }
            .sub-single-page .entry-header h1.entry-title{
                color: #4D4D4D;
                font-size: 20px;
                margin-bottom: 10px;
            }

            .video-container, #miniclip-game-embed { position: relative; padding-bottom: 56.25%; padding-top: 30px; height: 0; overflow: hidden; } 
            .video-container iframe, .video-container object, .video-container embed, #miniclip-game-embed iframe, #miniclip-game-embed object, #miniclip-game-embed embed { position: absolute; top: 0; left: 0; width: 100%; height: 100%; }


            #secondary h3{
                border-bottom: 1px solid #ccc;
                font-size: 20px;
                padding: 5px;
            }
            .contact_us aside{
                background-color: #EEEEEE;
                border: 2px solid #CCCCCC;
                padding: 10px;
                color: #555555;
            }
            .hover-info {
                text-align: justify;
            }
            .hover-info .more {
                color: #FFFFFF;
                xfont-family: 'oswald';
                font-size: 14px;
            }
            .hover-info .more:hover {
                color: #0489C0;
            }
            #secondary p{
                margin: 10px 0 20px;
            }
            .wpcf7-form input, .wpcf7-form textarea, .wpcf7-form select{
                width: 96%;
                border: 1px solid #ddd;
                margin: 10px 0;
                padding: 5px;
            }
            .wpcf7-form input.wpcf7-submit{
                width: auto;
                background-color: #0489C0;
                border: 1px solid #0489C0;
                color: #fff;
                padding: 5px 10px;
            }

            .width100p{
                width: 100%!important;
            }
            .gallery-item{
                margin-top: 0!important;
            }
            .gallery-item img{
                margin: 0!important;
                border-width: 5px 5px 0!important;
                border-style:solid!important;
                border-color:#FFFFFF!important;
                height: auto;
            }
            


            #masonry_wrap{
                padding-bottom: 50px;
            }
            #masonry_wrap .item{
                margin: 5px 0;
                text-align: center;
                border: 1px solid #ccc;
                padding: 3px;
            }
            #masonry_wrap .load_more_content{
                background: none repeat scroll 0 0 rgba(4,137,192, 0.4);
                bottom: 0;
                margin-left: 25%;
                padding: 10px 0;
                position: absolute;
                text-align: center;
                width: 50%;
                color: #FFFFFF;
                font-size: 22px;
                line-height: 24px;
                text-shadow: 2px 2px 2px #7D7D7D;
                border-radius: 10px;
            }
            
            
            
            header#branding .topHeader .topContent .social .inning a.instagram {
                background: url("<?php echo get_template_directory_uri(); ?>/images/instagram.png") no-repeat scroll 0 0!important;
            }
            
            header#branding .topHeader .topContent .social .inning a.user_icon{
                background: url("<?php echo get_template_directory_uri(); ?>/images/d-icon.png") no-repeat scroll 0 0!important;
            }




            /*fixed css*/
            input.wpcf7-submit{
                width: auto!important;
            }
            .colorbox_popup_wrapper .rightInfo strong{
                xdisplay: block;
                xmargin: 5px 0;
            }
            #secondary aside .textwidget{
                padding: 0;
                border-width: 0px;
            } 
            
            
           
            .user_icon_content{
                background: none repeat scroll 0 0 #FFFFFF;
                border: 1px solid #DDDDDD;
                display: none;
                padding: 10px;
                position: absolute;
                right: 0;
                width: 300px;
                margin-top: 33px;
                box-shadow: 1px 1px 5px ;
                z-index: 2;
            }
            
            .user_icon_number{
                border-radius: 2px;
                -webkit-border-radius: 2px;
                box-shadow: 0 1px 1px rgba(0, 0, 0, .7);
                -webkit-box-shadow: 0 1px 1px rgba(0, 0, 0, .7);
                background-color: #dc0d17;

                background-image: -webkit-gradient(linear, center top, center bottom, from(#fa3c45), to(#dc0d17));
                background-image: -webkit-linear-gradient(top, #fa3c45 0%, #dc0d17 100%);
                color: #fff;
                height: 15px;
                line-height: 15px;
                text-shadow: 0 -1px 0 rgba(0, 0, 0, .4);
                padding: 0 3px;
                font-size: 10px;
                right: -4px;
                top: -4px;  
                position: absolute;
            }
            .user_icon_triangle{
                width: 25px;
                height: 15px;
                background: url("<?php echo get_template_directory_uri(); ?>/images/triangle.png") no-repeat scroll 0 0!important;
                position: absolute;
                top: -12px;
                right: 20px;
                z-index: 1;
            }
             
            .user_icon_notification{
                background: none repeat scroll 0 0 #FFFFFF;
                border: 1px solid #DDDDDD;
                xdisplay: none;
                padding: 10px 30px 10px 10px;
                text-align: justify;
                position: absolute;
                right: -20px;
                width: 300px;
                margin-top: 43px;
                box-shadow: 1px 1px 5px ;
                z-index: 1;
                border-radius: 5px;
            }
            .user_icon_notification_content{
                line-height: 1.5em;
            }
            .user_icon_close {
                position: absolute;
                bottom: 0;
                right: 0;
                background: url(<?php echo get_template_directory_uri(); ?>/assets/colorbox/example1/images/controls.png) no-repeat -25px 0;
                width: 25px;
                height: 25px;
                text-indent: -9999px;
                cursor: pointer;
            }
            .user_icon_close:hover{
                background-position: -25px -25px;
            }
            #cus_login{
                z-index: 3;
            }
            
            
            .create_event_wrap {
                width: 100%;
            }
            .create_event_wrap a{
                color: #0489C0;
                text-decoration: none;
                margin: 20px 0 5px;
                display: block;
            }
            .create_event_wrap a:hover{
                text-decoration: underline;
            }
            .create_event_wrap fieldset{
                border: 1px solid #dddddd;
                padding: 10px;
                margin-top: 10px;
                width: 80%;
            }
            
            .fullcol{
                width: 96%;
                float: left;
            }
            .leftcol{
                float: left;
                width: 48%;
            }
            .rightcol{
                float: right;
                width: 48%;
            }
            .marginR20{
                margin-right: 20px;
            }
            
            .invalid{
                border: 1px solid #ff0000!important;
                color: #ff0000;
            }
            .red{
                color: #ff0000;
            }
            .refresh_button{
                background: none repeat scroll 0 0 #0489C0;
                border: 0 none;
                display: block;
                margin: 0 20px 0 auto;
                padding: 10px 20px;
                color: #fff;
                font-size: 12px;
                cursor: pointer;
            }
            
            
            .fix_head_menu{
                float: none!important;
                width:auto!important;
                height:auto!important;
            }
            .wpcf7-form textarea{
                height:120px;
            }
            
            .dropdown_effect1 {
                color: #08C;
                cursor: pointer;
                padding: 4px;
                border-radius: 4px;
            }
		
            .dropdown_effect1:after {
                font-family: Consolas, Courier New, Arial, sans-serif;
                content: '↓';
                margin-left: 6px;
                color: #08C;
            }
		
            .dropdown_effect1:hover {
                background: #F2F2F2;
            }
		
            .dropdown_effect1.dropdown-open {
                background: #888;
                color: #FFF;
            }
		
            .dropdown_effect1.dropdown-open:after {
                color: #FFF;
            }
            
            .fix_dropdown_position{
                left: auto!important;
                top: auto!important;
            }
            
            .fix_dropdown_position .dropdown-menu-ui LABEL {
                display: block;
                color: #555;
                text-decoration: none;
                line-height: 18px;
                padding-top: 0px;
                padding-bottom: 0px;
                white-space: nowrap;
            }

            .fix_dropdown_position .dropdown-menu-ui LABEL:hover {
                background-color: transparent;
                color: #555;
                cursor: pointer;
            }
            .fix_dropdown_position .dropdown-menu-ui LI {
                margin-left: 10px;
            }
            .paddingL10{
                padding-left: 10px;
            }
            
            /*notify me*/
            input[type=checkbox].css-checkbox {
                position: absolute; 
                overflow: hidden; 
                clip: rect(0 0 0 0); 
                height:1px; 
                width:1px; 
                margin:-1px; 
                padding:0;
                border:0;
            }

            input[type=checkbox].css-checkbox + label.css-label {
                padding-left:20px;
                height:15px; 
                display:inline-block;
                line-height:15px;
                background-repeat:no-repeat;
                background-position: 0 0;
                font-size:12px;
                vertical-align:middle;
                cursor:pointer;
            }

            input[type=checkbox].css-checkbox:checked + label.css-label {
                background-position: 0 -15px;
            }

            .css-label{
                background-image:url(http://csscheckbox.com/checkboxes/dark-check-green.png);
            }

            input[type=checkbox].css-checkbox.lrg + label.css-label.lrg {
                padding-left:22px;
                height: 20px; 
                display:inline-block;
                line-height:20px;
                background-repeat:no-repeat;
                background-position: 0 0;
                font-size:12px;
                vertical-align:middle;
                cursor:pointer;
            }

            input[type=checkbox].css-checkbox.lrg:checked + label.css-label.lrg{

                background-position: 0 -20px;
            }
            .vlad{background-image:url(http://csscheckbox.com/checkboxes/vlad.png);}

            .notify_me_content{
                background: none repeat scroll 0 0 #FFFFFF;
                border: 1px solid #DDDDDD;
                display: none;
                padding: 10px;
                position: absolute;
                right: 0;
                width: 300px;
            }
            /*end notify me*/
            
            .btn.selectpicker{
                padding: 2px 5px!important;
            }
            .dropdown-menu.inner.selectpicker{
                max-height: 100px!important;
            }
            .dropdown-menu.selectpicker > li > a{
                margin: 0;
            }
            
            .fix_dd_wrap label{
                display: block;
            }
            .fix_dd_wrap select{
                padding: 5px;
                margin: 5px;
                border: 1px solid #ccc;
            }
            
            /*contact form modification*/
            form.invalid{
                border: 0px!important;
            }
            div.wpcf7-validation-errors {
                border: 2px solid #FF0000;
                text-align: center;
                margin: 5px 0;
                color: #ff0000;
            }
            div.wpcf7-mail-sent-ok {
                border: 2px solid #398F14;
                text-align: center;
                margin: 5px 0;
                color: #398F14;
            }
            
            .info .box_description{
                padding: 0 15px;
            }
            
            
            .tribe-events-list .tribe-events-event-cost span.btn_style1, .tribe-events-single span.btn_style1{
                background: none repeat scroll 0 0 #F1F2F3 !important;
                border: 1px solid rgba(0, 0, 0, 0.35) !important;
                color: #0489C0 !important;
                cursor: pointer;
                text-transform: uppercase;
                font-style: normal;
                font-weight: bold;
                line-height: 1.3;
                font-family: 'open sans';
                padding: 5px 10px;
            }
            .tribe-events-list .tribe-events-event-cost span.btn_style1:hover, .tribe-events-single span.btn_style1:hover {
                background: none repeat scroll 0 0 #FBFBFC !important;
                border: 1px solid rgba(0, 0, 0, 0.65) !important;
                color: #0489C0 !important;
            }
            .event_title .tribe-events-event-cost {
                position: absolute !important;
                right: 7px;
                top: 7px;
            }
        </style>
        <script>
            function showLoading() {
                var value = '<p style="text-align:center;margin-top:28px;padding:0;"><img src="<?php echo get_template_directory_uri(); ?>/images/ajax-loader.gif" alt="loading..." /><span style="display:block;font-size:12px;color:#9A9A9A;">Loading...</span></p>';
                $.colorbox({html: value, width: "145px", height: "145px", fixed: true, overlayClose: false, closeButton: false});
            }
            function closeLoading() {
                $.fn.colorbox.close();
            }
            function activateMasonry() {
                var $container = jQuery('#masonry_wrap');
                $container.imagesLoaded(function() {
                    $container.masonry({
                        itemSelector: '.item',
                        isAnimated: true,
                        animationOptions: {
//    duration: 300,
                            easing: 'linear',
                            queue: false
                        },
                        gutterWidth: 20,
                        columnWidth: 280
                    });
                });
            }
            function reloadMasonry() {
                var $container = jQuery('#masonry_wrap');
                $container.imagesLoaded(function() {
                    $container.masonry('reload', function() {
                        //console.log('complete');  
                    });
                });
            }

            function loadMore(paged, template) {
                $.ajax({
                    type: "GET",
                    url: '<?php echo admin_url('admin-ajax.php'); ?>',
                    data: {
                        'action': 'masonry_paging',
                        'template': template,
                        'paged': paged,
                    },
                    beforeSend: function() {
                        $('.load_more_content').html('<img src="<?php echo get_template_directory_uri() . "/images/loading.gif"; ?>" alt="loading">');
                    },
                    complete: function() {
                    },
                    cache: false,
                    success: function(response) {
//        console.log(response);
                        $('.load_more_content').remove();
                        $('#masonry_wrap').append(response);
                        reloadMasonry();
                    },
                    error: function(error) {
                        alert("Some problems have occured. Please try again later: " + error);
                    }
                });
            }

            function showMessage(type, message) {
                type = (typeof type !== "undefined") ? type : "error"; //default error
                message = (typeof message !== "undefined") ? message : "Saved Successfully."; //default error msg.
                $.noticeAdd({
                    text: message, // content of the item
                    stay: true, // should the notice item stay or not?
                    inEffect: {opacity: 'show'}, // in effect
                    inEffectDuration: 600, // in effect duration in miliseconds
                    stayTime: 5000, // time in miliseconds before the item has to disappear
                    type: type                // could also be error, success or notice
                });
            }

            function showUserNotification(type, message) {
                $('.user_icon_notification_content').html(message);
                $('.user_icon_notification').show();
            }
            function closeUserNotification() {
                $('.user_icon_notification').hide();
            }


            var xhr;
            $(document).ready(function() {
                $("a.ajax_popup, .ajax_popup a").colorbox({fixed: false, overlayClose: false});
                $(".inline_popup").colorbox({inline: true, width: "50%", fixed: false, overlayClose: false});
                $(".inline_popup_fix").colorbox({inline: true, trapFocus: false, width: "80%", height: "90%", fixed: true, overlayClose: false});
                $(".iframe_popup").colorbox({iframe: true, width: "80%", height: "80%", fixed: false, overlayClose: false});
                $(".gallery dt.gallery-icon a").colorbox({rel: 'cboxElement', width: "50%", fixed: false, overlayClose: false});

                $('.event_notify_me').click(function() {
                    var rawVal = $(this).val();
                    var valList = rawVal.split('|');
                    var is_notify = ($(this).is(':checked')) ? 1 : 0;
                    var event_title = $(this).attr('alt');
                    var user_id = valList[0];
                    var post_id = valList[1];
                    if (typeof xhr !== 'undefined')
                        xhr.abort();
                    xhr = $.ajax({
                        type: "GET",
                        dataType: "json",
                        url: '<?php echo admin_url('admin-ajax.php'); ?>',
                        data: {
                            'action': 'dktm_event_notification',
                            'user_id': user_id,
                            'post_id': post_id,
                            'is_notify': is_notify,
                        },
                        beforeSend: function() {
                            showLoading();
                        },
                        complete: function() {
                            closeLoading();
                        },
                        cache: false,
                        success: function(response) {
                            var msg = '';
                            var type = 'error';
                            var status = 3;
                            if (response.status) {
                                type = "success";
                                if (response.is_notify == 1) {
                                    status = 1;
                                    msg = 'You have set a reminder for this event. A notification will be displayed here 2 days before the actual event. Please login to see all your notifications.';
                                } else {
                                    status = 2;
                                    msg = 'Reminder to this event has been successfully removed.';
                                }
                            } else {
                                type = 'error';
                                msg = 'Error occured. Please contact administrator.';
                            }
                            //redirect
                            var url = window.location.href;
                            if (url.indexOf('?') !== -1) {
                                var separator = '&notify_me=';
                                var temp = url.split(separator);
                                if (temp.length > 1) {
                                    var raw_val = temp[1]; //1&tstatus=false
                                    var temp2 = raw_val.split('&');
                                    if (temp2.length > 1) {
                                        url = temp[0] + separator + status + '&' + temp2[1];
                                    } else {
                                        url = temp[0] + separator + status;
                                    }
//                                    url += '&notify_me=' + status;
                                } else {
                                    url += separator + status;
                                }

                            } else {
//                                url += '?notify_me=' + status;
                                var separator = '?notify_me=';
                                var temp = url.split(separator);
                                if (temp.length > 1) {
                                    var raw_val = temp[1]; //1&tstatus=false
                                    var temp2 = raw_val.split('&');
                                    if (temp2.length > 1) {
                                        url = temp[0] + separator + status + '&' + temp2[1];
                                    } else {
                                        url = temp[0] + separator + status;
                                    }
//                                    url += '&notify_me=' + status;
                                } else {
                                    url += separator + status;
                                }
                            }
                            window.location.href = url;
//                            showUserNotification(type, msg);
                        },
                        error: function(error) {
                            xhr.abort();
                            alert("Some problems have occured. Please try again later: " + error);
                            closeLoading();
                        }
                    });
                });
            });


            $(document).ready(function() {
                $('.user_icon_trigger, .user_icon_content').hover(function() {//hover
                    $(this).parent().find('.user_icon_content').show();
                }, function() { //hover out
                    $(this).parent().find('.user_icon_content').hide();
                });
                $('.user_icon_close').click(function() {
                    $('.user_icon_notification').hide();
                });
            });
        </script>



        <script type="text/javascript">
            function changeEventAttribute(type, obj) { //type = venue|organizer
                var val = jQuery(obj).val();
                if (val == "0") {
                    jQuery(obj).parents('form').find('.' + type + '_detail_container').show();
                } else {
                    jQuery(obj).parents('form').find('.' + type + '_detail_container').hide();
                }
            }
            $(document).ready(function(jQuery) {
                jQuery('input[name="venue_name"]').blur(function() {
                    var obj = jQuery(this);
                    jQuery.post('<?php echo admin_url('admin-ajax.php'); ?>',
                            {
                                action: 'tribe_event_validation',
                                nonce: '<?php echo wp_create_nonce('tribe-validation-nonce'); ?>',
                                type: 'venue',
                                name: obj.val()
                            }, function(result) {
                        if (result == 1) {
                            obj.removeClass('invalid').addClass('valid');
                        } else {
                            obj.removeClass('valid').addClass('invalid');
                        }
                    }
                    );
                });

                jQuery('input[name="organizer_name"]').blur(function() {
                    var obj = jQuery(this);
                    jQuery.post('<?php echo admin_url('admin-ajax.php'); ?>',
                            {
                                action: 'tribe_event_validation',
                                nonce: '<?php echo wp_create_nonce('tribe-validation-nonce'); ?>',
                                type: 'organizer',
                                name: obj.val()
                            }, function(result) {
                        if (result == 1) {
                            obj.removeClass('invalid').addClass('valid');
                        } else {
                            obj.removeClass('valid').addClass('invalid');
                        }
                    }
                    );
                });

//                jQuery('.selectpicker').selectpicker({
//                    'selectedText': 'cat'
//                });
                // $('.selectpicker').selectpicker('hide');
            });
            jQuery(window).on('load', function() {
                jQuery('.selectpicker').selectpicker({
                    'selectedText': 'cat'
                });
                // $('.selectpicker').selectpicker('hide');
            });
            function toggleDiv(selector) {
                jQuery(selector).slideToggle();
            }
        </script>
    </head>

    <body <?php body_class(); ?>>
<!--        <span class="dropdown_effect1" data-dropdown="#dropdown-1">span</span>
        <a href="#" data-dropdown="#dropdown-1">Here’s a link</a>
        <input type="button" data-dropdown="#dropdown-1"/>
        <div id="dropdown-1" class="dropdown dropdown-tip">
            <ul class="dropdown-menu-ui">
                <li><a href="#1">Item 1</a></li>
                <li><a href="#2">Item 2</a></li>
                <li><a href="#3">Item 3</a></li>
                <li class="dropdown-divider"></li>
                <li><a href="#4">Item 4</a></li>
                <li><a href="#5">Item 5</a></li>
                <li><a href="#5">Item 6</a></li>
            </ul>
        </div>-->
        <div id="page" class="hfeed">
            <?php $pfs = new PostFromSite(); ?>
            <?php if (is_home() || is_front_page()) { ?>
                <div class="loading">
                    <div class="loaders" >
                        <img src="<?php echo get_template_directory_uri(); ?>/images/loader.gif" /> <br> <br>
                        <img src="<?php echo get_template_directory_uri(); ?>/images/logo_first.png" />
                    </div>
                </div>
            <?php } ?>
            <!--<div class="fix-part">
                <a href=""><div class="loadshedding"> <h1>Loadshedding Routine</h1><img src="<?php echo get_template_directory_uri(); ?>/images/load.png" alt=""></div></a>
            </div> -->
            <header id="branding" role="banner">
                <!--<hgroup>
                        <h1 id="site-title"><a href="<?php echo home_url('/'); ?>" title="<?php echo esc_attr(get_bloginfo('name', 'display')); ?>" rel="home"><?php bloginfo('name'); ?></a></h1>
                        <h2 id="site-description"><?php bloginfo('description'); ?></h2>
                </hgroup>-->

                <div class="topHeader">


                    <div class="topContent">
                        <div class="wrapper">
                            <nav id="access" role="navigation">
                                <?php dktm_main_nav(); ?>
                                <?php //wp_nav_menu( array( 'theme_location' => 'primary' ) );   ?>
                            </nav>
                            <div class="social" style="position:relative">

                                <div class="inning">
                                    <?php
                                    if (is_user_logged_in()) {
                                        global $current_user;
                                        get_currentuserinfo();
                                        ?>
                                        <a  id="loginin-btn" href="javascript:void(0);" class="loginin-btn" style="width: auto;padding: 0 10px;">Welcome, <?php echo $current_user->display_name; ?></a>
                                    <?php } else {
                                        ?>
                                        <a  id="loginin-btn" href="" class="loginin-btn">log in</a>
                                    <?php } ?>
                                    <?php //echo get_social_network_link('facebook'); ?>
                                    <?php //echo get_social_network_link('twitter'); ?>
                                    <?php //echo get_social_network_link('instagram'); ?>
                                    <?php //echo get_social_network_link('in'); ?>
                                    <?php //echo get_social_network_link('you'); ?>
                                    <?php echo get_user_icon(); ?>
                                </div>


                                <div style="display: none" id="cus_login">
                                    <?php
                                    if (!is_user_logged_in()) { // Display WordPress login form:
                                        get_dktm_login_form();
                                    } else { // If logged in:
                                        echo '<div class="logged_in">';
                                        wp_loginout(home_url()); // Display "Log Out" link.
                                        //wp_register('', ''); // Display "Site Admin" link.
                                        echo '</div>';
                                    }
                                    ?> 
                                </div>
                            </div>
                        </div>

                        <!--<div class="searchBar">
                                        <form method="get" action="/search" id="search">
                                                <input name="q" type="text" size="40" placeholder="Search..." />
                                        </form>
                                        
                                </div> -->
                    </div>
                    <div class="clear"></div>

                </div>

            </header><!-- #branding -->
            <div class="clear"></div>
            <nav class="access">
                <div class="subMenus">
                    <img src="<?php echo get_template_directory_uri(); ?>/images/logo_b.png" />
                    <!--                    <h1>Services</h1>-->
                    <div class="menu-services-container">
                        <?php dktm_side_nav(); ?>
                        <!--					<ul>
                                                                        <li><a href="">Information Centre</a></li>
                                                                        <li><a href="">D-ktm events</a></li>
                                                                        <li><a href="">D-ktm Bazar</a></li>
                                                                        <li><a href="">Our Networks</a></li>
                                                                        <li><a href="">Our Group[Bikeraus nepal]</a></li>
                                                                        <li><a href="">Forum</a></li>
                                                                        <li><a href="">Our Community</a></li>
                                                                        <li><a href="">Entertainment Zone</a></li>
                                                                </ul>-->
                    </div>			
                </div>
            </nav>
            <aside class="menuBtn">
                <span class="bar"></span>
                <span class="bar"></span>
                <span class="bar"></span>
                <h1>Menu</h1>
            </aside>
            <div id="main">
